//
//  AYMDoctorsCell.m
//  QuickCure
//
//  Created by kangkang on 16/5/7.
//  Copyright © 2016年 ayumi. All rights reserved.
//

#import "AYMDoctorsCell.h"

#import "AYMTumorModel.h"

@interface AYMDoctorsCell ()
@property (weak, nonatomic) IBOutlet UIImageView *iconImageView;
@property (weak, nonatomic) IBOutlet UILabel *nameLabel;
@property (weak, nonatomic) IBOutlet UILabel *nameTitleLabel;
@property (weak, nonatomic) IBOutlet UILabel *hospitalLabel;
@property (weak, nonatomic) IBOutlet UILabel *matchLabel;
@property (weak, nonatomic) IBOutlet UIButton *operationButton;
@property (weak, nonatomic) IBOutlet UIButton *flowerButton;
@property (weak, nonatomic) IBOutlet UIButton *bannerButton;
@property (weak, nonatomic) IBOutlet UIImageView *trailingImageView;

@end

@implementation AYMDoctorsCell

-(void)setModel:(AYMTumorModel *)model{
  
    _model = model;

     self.nameLabel.text = model.doctor_name;
    
    self.nameTitleLabel.text = model.doctor_title_name;
    
    self.hospitalLabel.text = model.doctor_hospital_name;
    
    self.matchLabel.text = model.accuracy;
    
    [self.operationButton setTitle:[NSString stringWithFormat:@"手术：%@",model.operation_count] forState:UIControlStateNormal];
    
    [self.operationButton setImage:[UIImage imageNamed:@"yuyueliang"] forState:UIControlStateNormal];
    
    [self.flowerButton setTitle:[NSString stringWithFormat:@"鲜花：%@",model.flower] forState:UIControlStateNormal];
    
    [self.flowerButton setImage:[UIImage imageNamed:@"xianhua"] forState:UIControlStateNormal];
    
    [self.bannerButton setTitle:[NSString stringWithFormat:@"锦旗：%@",model.banner] forState:UIControlStateNormal];
    
    [self.bannerButton setImage:[UIImage imageNamed:@"jinqi"] forState:UIControlStateNormal];
    
    self.trailingImageView.image = [UIImage imageNamed:@"jt"];
    
    [self.iconImageView sd_setImageWithURL:[NSURL URLWithString:model.doctor_portrait] placeholderImage:[UIImage imageNamed:@"name"] options:SDWebImageRetryFailed];

 }



@end
